The present invention relates to an image processing method and image forming apparatus, and specifically to an image processing method and image forming apparatus by which the image can be formed while an inclination of an image is being quickly corrected.
When an inclination is generated in the image data obtained by reading a document by a scanner, a method by which the image data is stored in a memory and the inclination correction processing is carried out at the time of reading out, is applied. For example, the description relating to this kind of correction processing is also disclosed in Japanese Tokkaihei No. 10-191026.
In the above inclination correction method, because it is necessary that whole image data is written in the memory once, a time to write in the memory and to read from the memory is necessary at the time of the inclination correction.
That is, for the image data obtained by reading the document, it is necessary that writing and reading for one image area are carried out, and there is a problem that the image formation can not be attained in real time while reading out the image data.
Further, in this inclination correction method, at least a memory for one image area is necessary, and there is a problem that the large capacity memory is necessary for storing the image data of the read out document.
Accordingly, the object of the present invention is to realize an image processing method and an image forming apparatus which do not need a large capacity memory for the inclination correction, and can correct the inclination in a short time.
That is, the present invention to solve the above problem is as follows.
The present invention is an image processing method, which comprising steps of: an inclination detecting step to detect the inclination of the image data; a main scanning correction step to store the image data for one line, and by changing the read out timing when the image data is read out, corresponding to the detected inclination, to correct a shift in the main scanning direction; and a sub-scanning correction step to store the image data for n lines (n is an integer not smaller than 2), and by changing the line position in the sub-scanning direction when the image data is read out, corresponding to the detected inclination, to correct a shift in the sub-scanning direction.
Further, the present invention is an image processing method, which comprising steps of: an inclination detecting step to detect the inclination of the image data; a main scanning correction step by which the writing timing when the image data for one line is stored, is changed corresponding to the detected inclination, and by reading out the image data in a normal timing, a shift in the main scanning direction is corrected; and a sub-scanning correction step by which a line position in the sub-scanning direction when the image data is written into the memory means, is changed corresponding to the detected inclination, for the image data not smaller than 2 lines, and the image data is read out at a normal line position and a shift in the sub-scanning direction is corrected.
Further, the present invention is an image forming apparatus, which comprising: an inclination detecting means for detecting an inclination of the image data which is a set of line-like pixels; a main scanning correction means for storing the image data for one line, and for correcting a shift in the main scanning direction by changing a reading out timing when the image data is read out, corresponding to the detected inclination; and a sub-scanning correction means for storing the image data for n lines (n is an integer not smaller than 2), and for correcting a shift in the sub-scanning direction by changing the line position in the sub-scanning direction when the image data is read out, corresponding to the detected inclination.
Further, the present invention is an image forming apparatus, which comprising: an inclination detecting means for detecting an inclination of the image data which is a set of line-like pixels; a main scanning correction means for changing the writing timing when the image data for one line is stored, corresponding to the detected inclination, and by reading out the image data at a normal timing, for correcting a shift in the main scanning direction; and a sub-scanning correction means for changing a line position in the sub-scanning direction when the image data is written into the memory means, corresponding to the detected inclination, for the image data for n lines (n is an integer not smaller than 2), and for reading out the image data at a normal line position and for correcting a shift in the sub-scanning direction.
Incidentally, it is preferable that, in the main scanning correction, correction is conducted at intervals of every m lines (m is an integer not smaller than 1), and in the sub-scanning correction, correction is conducted at intervals of every lines which is not smaller than 2, and not more than n (n is an integer not smaller than 2).
In the present invention, the inclination of the image data is detected, and by changing the reading out timing when the image data for m lines is read out (or writing timing when the image data is written) corresponding to the inclination, a shift in the main scanning direction is corrected, and the image data for not smaller than 2 lines, is stored, and by changing the line position in the sub-scanning direction when the image data is read out, (or the line position in the sub-scanning direction when the image data is written) corresponding to the detected inclination, a shift in the sub-scanning direction is corrected.
In this case, it is preferable that, after the main scanning correction means conducts the correction in the main scanning correction means, the sub-scanning correction means conducts the correction in the sub-scanning direction.
Herein, because a memory for one line for the main scanning direction, and a memory for n (n is an integer not smaller than 2) lines for the sub-scanning direction are necessary, a line memory for (1+n) lines is sufficient. Further, basically, the processing is for each line, and the inclination correction can be conducted while reading is being conducted, therefore, the inclination correcting processing can be conducted in almost real time.
As the result, the image processing method and the image forming apparatus by which a large capacity memory is not necessary for the inclination correction, and the inclination correction can be conducted in a short time, can be realized.
Incidentally, it is preferable that the sub-scanning correction means changes the number of lines which is written in the sub-scanning correction means corresponding to the number of gradations of the image data, for example, such as 8-line correction in the one bit gradation, and 4-line correction in the 2-bit gradation. As described above, for the correction of the inclination in the sub-scanning direction, because the number of lines when n lines are written in the sub-scanning correction memory, is controlled corresponding to the number of gradations of the image data, thereby, the sub-scanning correction memory can be effectively used.
Further, it is preferable that the correction of the main scanning direction and correction of the sub-scanning direction are conducted by the offset movement from the position at which the document is read out. When the inclination correction of the image data accompanied by such the offset correction is conducted, the setting of the effective image area in which the actual image formation is conducted when the inclination correction is conducted, can be optimum, and the correction of the image can be properly conducted.
Further, when the inclination amount from the inclination detecting means exceeds the maximum correction amount of the main scanning correction means or the sub-scanning correction means, it is desirable that the maximum correction amount is corrected as the inclination amount.
According to this, the inclination correction can be conducted without the operation being interrupted. Incidentally, when the detected inclination amount exceeds the inclination amount allowable for the image quality (a slight inclination amount within an amount in which the inclination is visually sensed) from that, in addition to the maximum correction amount, it is desirable to display that the inclination of the document exceeds the correction amount.
Furthermore, the further preferable structures are as follows.
(a) An image reading apparatus, which having the structures of: an image reading device for reading out an image of a document; an image input device for receiving the image data read out by the image, reading device; a detecting device for detecting an inclination of the image data which is a set of line-like pixels; a main scanning correction device for storing the image data for one line in a first memory, and for correcting a shift in the main scanning direction, by changing the reading out timing when the image data is read out from the first memory, corresponding to the inclination detected by the detecting device; a sub-scanning correction device for storing the image data for n lines (n is an integer not smaller than 2) in a second memory, and for correcting a shift in the sub-scanning direction, by changing a line position in the sub-scanning direction when the image data is read out from the second memory, corresponding to the inclination detected by the detecting device; an image storing device for storing the image data corrected by the main scanning correction device and the sub-scanning correction device; and a controller for controlling operations of the image input device, detecting device, main scanning correction device, and sub-scanning correction device.
(b) An image reading apparatus, which having the following structures of: an image reading device for reading out an image of a document; an image input device for receiving the image data read out by the image reading device; a detecting device for detecting an inclination of the image data which is a set of line-like pixels; a main scanning correction device for changing the writing timing when the image data for one line is stored in the first memory, corresponding to the inclination detected by the detecting device, and for correcting a shift in the main scanning direction by reading out the image data in a normal timing from the first memory; a sub-scanning correction device for changing the line position in the sub-scanning direction when the image data for n (n is an integer not smaller than 2) lines is written into a second memory, corresponding to the inclination detected by the detecting device, and for correcting a shift in the sub-scanning direction by reading out the image data at a normal line position; an image storing device for storing the image data corrected by the main scanning correction device and the sub-scanning correction device; and a controller for controlling the operations of the image input device, the detecting device, the main scanning correction device, and the sub-scanning correction device.
(c) Further, an image forming apparatus, which having the structures of: an image input device for receiving the image data; a detecting device for detecting an inclination of the image data which is a set of line-like pixels; a main scanning correction device for storing the image data for one line in a first memory and for correcting a shift in the main scanning direction, by changing the reading out timing when the image data is read out, corresponding to the inclination detected by the detecting device; a sub-scanning correction device for storing the image data for n (n is an integer not smaller than 2) lines in a second memory, and for correcting a shift in the sub-scanning direction, by changing the line position in the sub-scanning direction when the image data is read out, corresponding to the inclination detected by the detecting device; an image storing device for storing the image data corrected by the main scanning correction device and the sub-scanning correction device; a controller for controlling the operations of the image input device, the detecting device, the main scanning correction device, and the sub-scanning correction device; and an image forming device for forming the image based on the image data stored in the image storing device.
(d) Furthermore, an image forming apparatus, which having the structures of: an image input device for receiving the image data; a detecting device for detecting an inclination of the image data which is a set of line-like pixels; a main scanning correction device for changing the writing timing when the image data for one line is stored in a first memory, corresponding to the inclination detected by the detecting device, and for correcting a shift in the main scanning direction by reading out the image data in a normal timing; a sub-scanning correction device for changing the line position in the sub-scanning direction when the image data for the image data for n (n is an integer not smaller than 2) lines is written into a second memory, corresponding to the inclination detected by the detecting device, and for correcting a shift in the sub-scanning direction by reading out the image data at a normal line position; an image storing device for storing the image data corrected by the main scanning correction device and the sub-scanning correction device; a controller for controls the operations of the image input device, the detecting device, the main scanning correction device, and the sub-scanning correction device; and an image forming device for forming the image based on the image data stored in the image storing device.
The first memory and the second memory set forth in the present invention may be included in the same and common memory or used as respectively independent memories. In the case that the same and common memory is applied, it is possible to reduce the number of memories, on the contrary, in the case that the independent memories are applied, it can be easier to conduct the inclination correction processing.